package com.zy.explore.license.interfaces.assembler;

import com.zy.explore.license.application.service.StatisticsService;
import com.zy.explore.license.interfaces.vo.DataOverViewVO;
import com.zy.explore.license.interfaces.vo.RecentVisitDataVO;
import org.springframework.stereotype.Component;

import javax.annotation.Resource;

/**
 * 用户模块数据Assembler
 *
 * @author ChinaYin  主页:https://gitee.com/zy-explorej2ee 邮箱:zyexplorej2ee@sina.com
 * @date 2021年06月13日 12:13:50
 */
@Component
public class StatisticsAssembler {

    @Resource
    private StatisticsService statisticsService;

    /**
     * 查询统计数据
     *
     * @return {@link DataOverViewVO}
     */
    public DataOverViewVO getDataOverView() {
        return statisticsService.getDataOverView();
    }

    /**
     * 查询首页最近N天访问数据
     *
     * @param recentDays 最近天数
     * @return {@link RecentVisitDataVO}
     */
    public RecentVisitDataVO getRecentVisitData(int recentDays) {
        return statisticsService.getRecentVisitData(recentDays);
    }
}
